package com.huluobo.a2201mvvm_imdemo.shop;

import androidx.lifecycle.MutableLiveData;

import com.huluobo.a2201mvvm_imdemo.mvvm.BaseViewModel;

/**
 * Created by LC on 2024/4/8.
 */
public class ShopViewModel extends BaseViewModel<ShopRepo> {

    MutableLiveData<GoodsBeanResult> success = new MutableLiveData<>();

    MutableLiveData<String> failed = new MutableLiveData<>();

    public void getGoodsList(int categoryId, int currentPage, int pageSize) {
        repo.getGoodsList(categoryId, currentPage, pageSize, success, failed);
    }

    @Override
    protected ShopRepo createRepo() {
        return new ShopRepo();
    }
}
